home *** CD-ROM | disk | FTP | other *** search
/ SuperHack / SuperHack CD.bin / CODING / VBASIC / NW41BAS.ZIP / NW4XDIR.BAS < prev    next >
Encoding:
BASIC Source File  |  1995-04-15  |  5.5 KB  |  97 lines

  1. 'NW4XDIR.BAS - Visual Basic Interface File for Netware 4.X SDK
  2. '   Contains Function defination and type declarations for Directory
  3. '   Creation, Information Retrieval and Deletion
  4. 'Created by Joseph A. DiVito - Seton Hall University
  5. 'Requirments - NW4XCOMM.BAS
  6. 'Corresponds to NWDIRECT.H in the Netware SDK
  7.  
  8.  
  9. 'Trustee Access Rights in a network directory
  10. 'NOTE: TA_OPEN is obsolete in 3.x
  11.  
  12. Global Const TA_NONE = &H0
  13. Global Const TA_READ = &H1
  14. Global Const TA_WRITE = &H2
  15. Global Const TA_OPEN = &H4
  16. Global Const TA_CREATE = &H8
  17. Global Const TA_DELETE = &H10
  18. Global Const TA_OWNERSHIP = &H20
  19. Global Const TA_SEARCH = &H40
  20. Global Const TA_MODIFY = &H80
  21. Global Const TA_ALL = &HFB
  22.  
  23. Type TRUSTEE_INFO
  24.   objectID As Long
  25.   objectRights As Integer
  26. End Type
  27.  
  28. Declare Function NWAddTrusteeToDirectory Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$, ByVal trusteeID&, ByVal rightsMask%) As Integer
  29. Declare Function NWDeleteTrusteeFromDirectory Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$, ByVal objectID&) As Integer
  30. Declare Function NWGetEffectiveDirectoryRights Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$, rightsMask%) As Integer
  31. Declare Function NWModifyMaximumRightsMask Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$, ByVal revokeRightsMask%, ByVal grantRightsMask%) As Integer
  32. Declare Function NWScanDirectoryForTrustees Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle$, ByVal searchDirPath$, sequenceNumber%, ByVal dirName$, dirDateTime&, ownerID&, trusteeIDs&, trusteeRights%) As Integer
  33. Declare Function NWScanDirectoryForTrustees2 Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal searchDirPath$, sequenceNumber&, ByVal dirName$, dirDateTime&, ownerID&, trusteeList As TRUSTEE_INFO) As Integer
  34.  
  35. 'Global Const NWScanDirectoryInformation(a, b, c, d, e, f, g, h) \
  36. '  NWIntScanDirectoryInformation(a, b, c, d, e, f, g, h, 0)
  37.  
  38. Declare Function NWIntScanDirectoryInformation Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal searchDirPath$, sequenceNumber%, ByVal dirName$, dirDateTime&, ownerID&, rightsMask%, ByVal augmentFlag%) As Integer
  39.  
  40. 'Global Const NWScanDirectoryInformation2(a, b, c, d, e, f, g, h) \
  41. '        NWIntScanDirectoryInformation2(a, b, c, d, e, f, g, h, 0)
  42.  
  43. Declare Function NWIntScanDirectoryInformation2 Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal searchDirPath$, sequenceNumber%, ByVal dirName$, dirDateTime&, ownerID&, rightsMask%, ByVal augmentFlag) As Integer
  44. Declare Function NWSetDirectoryInformation Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$, ByVal dirDateTime&, ByVal ownerID&, ByVal rightsMask%) As Integer
  45. Declare Function NWSaveDirectoryHandle Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal saveBuffer$) As Integer
  46. Declare Function NWRestoreDirectoryHandle Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal saveBuffer$, newDirHandle%, rightsMask%) As Integer
  47. Declare Function NWAllocPermanentDirectoryHandle Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$, newDirHandle&, effectiveRights%) As Integer
  48. Declare Function NWAllocTemporaryDirectoryHandle Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$, newDirHandle&, rightsMask%) As Integer
  49. Declare Function NWDeallocateDirectoryHandle Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%) As Integer
  50. Declare Function NWSetDirectoryHandlePath Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal sourceDirHandle%, ByVal dirPath$, ByVal destDirHandle%) As Integer
  51. Declare Function NWGetDirectoryHandlePath Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$) As Integer
  52. Declare Function NWCreateDirectory Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$, ByVal accessMask%) As Integer
  53. Declare Function NWDeleteDirectory Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal dirPath$) As Integer
  54. Declare Function NWRenameDirectory Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal oldDirName$, ByVal newDirName$) As Integer
  55. Declare Function NWSetDirSpaceLimit Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal spaceLimit&) As Integer
  56. 'ReturnBuff is a String of Bytes representing Limitations - Init to String * 32
  57. Declare Function NWGetDirSpaceLimitList Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal returnBuff$) As Integer
  58. Declare Function NWGetDirSpaceInfo Lib "NWCALLS.DLL" (ByVal ConnID%, ByVal dirHandle%, ByVal volNumber%, spaceInfo As DIR_SPACE_INFO) As Integer
  59.  
  60. Global Const TF_NORMAL = &H0
  61. Global Const TF_READ_ONLY = &H1
  62. Global Const TF_HIDDEN = &H2
  63. Global Const TF_SYSTEM = &H4
  64. Global Const TF_EXECUTE_ONLY = &H8
  65.  
  66. Global Const TF_DIRECTORY = &H10
  67. Global Const TF_NEEDS_ARCHIVED = &H20
  68. Global Const TF_EXECUTE_CONFIRM = &H40
  69. Global Const TF_SHAREABLE = &H80
  70.  
  71. Global Const TF_LOW_SEARCH_BIT = &H100
  72. Global Const TF_MID_SEARCH_BIT = &H200
  73. Global Const TF_HI_SEARCH_BIT = &H400
  74. Global Const TF_PRIVATE = &H800
  75.  
  76. Global Const TF_TRANSACTIONAL = &H1000
  77. Global Const TF_INDEXED = &H2000
  78. Global Const TF_READ_AUDIT = &H4000
  79. Global Const TF_WRITE_AUDIT = &H8000
  80.  
  81. Global Const TF_PURGE = &H10000
  82. Global Const TF_RENAME_INHIBIT = &H20000
  83. Global Const TF_DELETE_INHIBIT = &H40000
  84. Global Const TF_COPY_INHIBIT = &H80000
  85. Global Const TF_AUDITING_BIT = &H100000
  86.  
  87. 'DIRECTORY ATTRIBUTES
  88.  
  89. Global Const TD_HIDDEN = TF_HIDDEN
  90. Global Const TD_SYSTEM = TF_SYSTEM
  91. Global Const TD_PURGE = TF_PURGE
  92. Global Const TD_PRIVATE = TF_PRIVATE
  93. Global Const TD_VISIBLE = TF_PRIVATE
  94. Global Const TD_RENAME_INHIBIT = TF_RENAME_INHIBIT
  95. Global Const TD_DELETE_INHIBIT = TF_DELETE_INHIBIT
  96.  
  97.